Skip to content

Fix ECC validation regression#10260

Merged
JacobBarthelmeh merged 1 commit intowolfSSL:masterfrom
Frauschi:ecc_fix
Apr 24, 2026
Merged

Fix ECC validation regression#10260
JacobBarthelmeh merged 1 commit intowolfSSL:masterfrom
Frauschi:ecc_fix

Conversation

@Frauschi
Copy link
Copy Markdown
Contributor

Fix a regression accidentally added in #9851 due to rebasing after #10133 has landed. Added a test to catch this in the future.
Fixes zd#21654.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 20, 2026

MemBrowse Memory Report

No memory changes detected for:

@Frauschi
Copy link
Copy Markdown
Contributor Author

Jenkins retest this please

@JacobBarthelmeh
Copy link
Copy Markdown
Contributor

Retest this please Jenkins. The history is no longer available.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Fixes a regression in ECC point validation during X9.63 public key import by ensuring the legacy import wrapper treats inputs as untrusted, and adds a regression test to catch off-curve points in the future.

Changes:

  • Update wc_ecc_import_x963_ex to pass untrusted=1 so imported points are validated as on-curve.
  • Add an API test that imports a deliberately off-curve P-256 point and expects rejection.
  • Register the new test in the ECC API test header.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
wolfcrypt/src/ecc.c Restores on-curve validation by treating X9.63 imports as untrusted in the wrapper.
tests/api/test_ecc.h Declares and registers a new ECC X9.63 off-curve regression test.
tests/api/test_ecc.c Adds a regression test asserting off-curve X9.63 points are rejected.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread tests/api/test_ecc.c
Comment thread tests/api/test_ecc.c
@Frauschi
Copy link
Copy Markdown
Contributor Author

Jenkins retest this please

@Frauschi
Copy link
Copy Markdown
Contributor Author

Jenkins retest this please

@Frauschi Frauschi assigned wolfSSL-Bot and unassigned Frauschi Apr 23, 2026
@JacobBarthelmeh JacobBarthelmeh merged commit c6953b8 into wolfSSL:master Apr 24, 2026
448 checks passed
@Frauschi Frauschi deleted the ecc_fix branch April 24, 2026 20:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants